﻿
using ETModel;

namespace ETHotfix {
    [ObjectSystem]
    public class GameSceneStart : StartSystem<HotfixComponent> {
        public override void Start(HotfixComponent self) {
            if (StartConfigComponent.Instance.StartConfig.AppType.HasFlag(AppType.Map)) {
                GameSceneRes.Start();
            }
        }
    }
    /// <summary>
    /// 场景资源,只有Map服务器可用
    /// </summary>
    public static class GameSceneRes {
        public static void Start() {
            //加入寻路组件
            if (Game.Scene.GetComponent<PathfindingComponent>() == null) Game.Scene.AddComponent<PathfindingComponent, string>("./Res/graph.bytes");

        }
    }
}
